﻿using System;
using System.Threading.Tasks;
using Quartz;

namespace NetCoreQuartzDemo
{
    [QuartzSet("第一个计划任务", "myGroup")]
    public class MyJob: Ibase
    {
        public Task Execute(IJobExecutionContext context)
        {
           return Task.Run(() =>
           {
               Console.WriteLine();
               Console.WriteLine($"<------------------MyJob------------------>每10秒执行一次【{DateTime.Now:HH:mm:ss}】");
               Console.WriteLine();
           });
        }
    }
}